package com.hornsun.domain.dbo;

import java.util.ArrayList;
import java.util.List;

public class PrescriptionExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public PrescriptionExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andPrescriptionGuidIsNull() {
            addCriterion("prescription_guid is null");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidIsNotNull() {
            addCriterion("prescription_guid is not null");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidEqualTo(String value) {
            addCriterion("prescription_guid =", value, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidNotEqualTo(String value) {
            addCriterion("prescription_guid <>", value, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidGreaterThan(String value) {
            addCriterion("prescription_guid >", value, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidGreaterThanOrEqualTo(String value) {
            addCriterion("prescription_guid >=", value, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidLessThan(String value) {
            addCriterion("prescription_guid <", value, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidLessThanOrEqualTo(String value) {
            addCriterion("prescription_guid <=", value, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidLike(String value) {
            addCriterion("prescription_guid like", value, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidNotLike(String value) {
            addCriterion("prescription_guid not like", value, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidIn(List<String> values) {
            addCriterion("prescription_guid in", values, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidNotIn(List<String> values) {
            addCriterion("prescription_guid not in", values, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidBetween(String value1, String value2) {
            addCriterion("prescription_guid between", value1, value2, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andPrescriptionGuidNotBetween(String value1, String value2) {
            addCriterion("prescription_guid not between", value1, value2, "prescriptionGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidIsNull() {
            addCriterion("drug_guid is null");
            return (Criteria) this;
        }

        public Criteria andDrugGuidIsNotNull() {
            addCriterion("drug_guid is not null");
            return (Criteria) this;
        }

        public Criteria andDrugGuidEqualTo(String value) {
            addCriterion("drug_guid =", value, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidNotEqualTo(String value) {
            addCriterion("drug_guid <>", value, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidGreaterThan(String value) {
            addCriterion("drug_guid >", value, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidGreaterThanOrEqualTo(String value) {
            addCriterion("drug_guid >=", value, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidLessThan(String value) {
            addCriterion("drug_guid <", value, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidLessThanOrEqualTo(String value) {
            addCriterion("drug_guid <=", value, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidLike(String value) {
            addCriterion("drug_guid like", value, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidNotLike(String value) {
            addCriterion("drug_guid not like", value, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidIn(List<String> values) {
            addCriterion("drug_guid in", values, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidNotIn(List<String> values) {
            addCriterion("drug_guid not in", values, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidBetween(String value1, String value2) {
            addCriterion("drug_guid between", value1, value2, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andDrugGuidNotBetween(String value1, String value2) {
            addCriterion("drug_guid not between", value1, value2, "drugGuid");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayIsNull() {
            addCriterion("times_oneday is null");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayIsNotNull() {
            addCriterion("times_oneday is not null");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayEqualTo(Integer value) {
            addCriterion("times_oneday =", value, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayNotEqualTo(Integer value) {
            addCriterion("times_oneday <>", value, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayGreaterThan(Integer value) {
            addCriterion("times_oneday >", value, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayGreaterThanOrEqualTo(Integer value) {
            addCriterion("times_oneday >=", value, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayLessThan(Integer value) {
            addCriterion("times_oneday <", value, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayLessThanOrEqualTo(Integer value) {
            addCriterion("times_oneday <=", value, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayIn(List<Integer> values) {
            addCriterion("times_oneday in", values, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayNotIn(List<Integer> values) {
            addCriterion("times_oneday not in", values, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayBetween(Integer value1, Integer value2) {
            addCriterion("times_oneday between", value1, value2, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andTimesOnedayNotBetween(Integer value1, Integer value2) {
            addCriterion("times_oneday not between", value1, value2, "timesOneday");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceIsNull() {
            addCriterion("capacity_once is null");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceIsNotNull() {
            addCriterion("capacity_once is not null");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceEqualTo(Float value) {
            addCriterion("capacity_once =", value, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceNotEqualTo(Float value) {
            addCriterion("capacity_once <>", value, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceGreaterThan(Float value) {
            addCriterion("capacity_once >", value, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceGreaterThanOrEqualTo(Float value) {
            addCriterion("capacity_once >=", value, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceLessThan(Float value) {
            addCriterion("capacity_once <", value, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceLessThanOrEqualTo(Float value) {
            addCriterion("capacity_once <=", value, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceIn(List<Float> values) {
            addCriterion("capacity_once in", values, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceNotIn(List<Float> values) {
            addCriterion("capacity_once not in", values, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceBetween(Float value1, Float value2) {
            addCriterion("capacity_once between", value1, value2, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andCapacityOnceNotBetween(Float value1, Float value2) {
            addCriterion("capacity_once not between", value1, value2, "capacityOnce");
            return (Criteria) this;
        }

        public Criteria andDaysIsNull() {
            addCriterion("days is null");
            return (Criteria) this;
        }

        public Criteria andDaysIsNotNull() {
            addCriterion("days is not null");
            return (Criteria) this;
        }

        public Criteria andDaysEqualTo(Float value) {
            addCriterion("days =", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysNotEqualTo(Float value) {
            addCriterion("days <>", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysGreaterThan(Float value) {
            addCriterion("days >", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysGreaterThanOrEqualTo(Float value) {
            addCriterion("days >=", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysLessThan(Float value) {
            addCriterion("days <", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysLessThanOrEqualTo(Float value) {
            addCriterion("days <=", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysIn(List<Float> values) {
            addCriterion("days in", values, "days");
            return (Criteria) this;
        }

        public Criteria andDaysNotIn(List<Float> values) {
            addCriterion("days not in", values, "days");
            return (Criteria) this;
        }

        public Criteria andDaysBetween(Float value1, Float value2) {
            addCriterion("days between", value1, value2, "days");
            return (Criteria) this;
        }

        public Criteria andDaysNotBetween(Float value1, Float value2) {
            addCriterion("days not between", value1, value2, "days");
            return (Criteria) this;
        }

        public Criteria andAmountIsNull() {
            addCriterion("amount is null");
            return (Criteria) this;
        }

        public Criteria andAmountIsNotNull() {
            addCriterion("amount is not null");
            return (Criteria) this;
        }

        public Criteria andAmountEqualTo(Float value) {
            addCriterion("amount =", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountNotEqualTo(Float value) {
            addCriterion("amount <>", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountGreaterThan(Float value) {
            addCriterion("amount >", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountGreaterThanOrEqualTo(Float value) {
            addCriterion("amount >=", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountLessThan(Float value) {
            addCriterion("amount <", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountLessThanOrEqualTo(Float value) {
            addCriterion("amount <=", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountIn(List<Float> values) {
            addCriterion("amount in", values, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountNotIn(List<Float> values) {
            addCriterion("amount not in", values, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountBetween(Float value1, Float value2) {
            addCriterion("amount between", value1, value2, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountNotBetween(Float value1, Float value2) {
            addCriterion("amount not between", value1, value2, "amount");
            return (Criteria) this;
        }

        public Criteria andUsagesIsNull() {
            addCriterion("usages is null");
            return (Criteria) this;
        }

        public Criteria andUsagesIsNotNull() {
            addCriterion("usages is not null");
            return (Criteria) this;
        }

        public Criteria andUsagesEqualTo(String value) {
            addCriterion("usages =", value, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesNotEqualTo(String value) {
            addCriterion("usages <>", value, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesGreaterThan(String value) {
            addCriterion("usages >", value, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesGreaterThanOrEqualTo(String value) {
            addCriterion("usages >=", value, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesLessThan(String value) {
            addCriterion("usages <", value, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesLessThanOrEqualTo(String value) {
            addCriterion("usages <=", value, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesLike(String value) {
            addCriterion("usages like", value, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesNotLike(String value) {
            addCriterion("usages not like", value, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesIn(List<String> values) {
            addCriterion("usages in", values, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesNotIn(List<String> values) {
            addCriterion("usages not in", values, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesBetween(String value1, String value2) {
            addCriterion("usages between", value1, value2, "usages");
            return (Criteria) this;
        }

        public Criteria andUsagesNotBetween(String value1, String value2) {
            addCriterion("usages not between", value1, value2, "usages");
            return (Criteria) this;
        }

        public Criteria andUnitIsNull() {
            addCriterion("unit is null");
            return (Criteria) this;
        }

        public Criteria andUnitIsNotNull() {
            addCriterion("unit is not null");
            return (Criteria) this;
        }

        public Criteria andUnitEqualTo(String value) {
            addCriterion("unit =", value, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitNotEqualTo(String value) {
            addCriterion("unit <>", value, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitGreaterThan(String value) {
            addCriterion("unit >", value, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitGreaterThanOrEqualTo(String value) {
            addCriterion("unit >=", value, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitLessThan(String value) {
            addCriterion("unit <", value, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitLessThanOrEqualTo(String value) {
            addCriterion("unit <=", value, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitLike(String value) {
            addCriterion("unit like", value, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitNotLike(String value) {
            addCriterion("unit not like", value, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitIn(List<String> values) {
            addCriterion("unit in", values, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitNotIn(List<String> values) {
            addCriterion("unit not in", values, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitBetween(String value1, String value2) {
            addCriterion("unit between", value1, value2, "unit");
            return (Criteria) this;
        }

        public Criteria andUnitNotBetween(String value1, String value2) {
            addCriterion("unit not between", value1, value2, "unit");
            return (Criteria) this;
        }

        public Criteria andRemarkIsNull() {
            addCriterion("remark is null");
            return (Criteria) this;
        }

        public Criteria andRemarkIsNotNull() {
            addCriterion("remark is not null");
            return (Criteria) this;
        }

        public Criteria andRemarkEqualTo(String value) {
            addCriterion("remark =", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkNotEqualTo(String value) {
            addCriterion("remark <>", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkGreaterThan(String value) {
            addCriterion("remark >", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkGreaterThanOrEqualTo(String value) {
            addCriterion("remark >=", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkLessThan(String value) {
            addCriterion("remark <", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkLessThanOrEqualTo(String value) {
            addCriterion("remark <=", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkLike(String value) {
            addCriterion("remark like", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkNotLike(String value) {
            addCriterion("remark not like", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkIn(List<String> values) {
            addCriterion("remark in", values, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkNotIn(List<String> values) {
            addCriterion("remark not in", values, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkBetween(String value1, String value2) {
            addCriterion("remark between", value1, value2, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkNotBetween(String value1, String value2) {
            addCriterion("remark not between", value1, value2, "remark");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}